<?php namespace testsacvoyage\app;
/*
namespace sacvoyage\domain;
class Collection {  }

namespace testsacvoyage\app;

use sacvoyage\domain\Collection;

require_once 'sacvoyage/Object.php';
use \sacvoyage\Object;

require_once 'sacvoyage/domain/Resource.php';
use \sacvoyage\domain\Resource;

require_once('testsacvoyage/app/AbstractTest.php');

require_once 'sacvoyage/app/FileApplication.php';
use \sacvoyage\app\FileApplication;


class FakeCollection extends Collection {
	
	public function read($id, $rev=null) {
		if($id=='style.js' && $rev==null) {
			return new Object(array(
				'_id'=>'style.js',
				'content-type'=>'text/css',
				'content'=>' some styles '			
			));
		} else {
			throw new Exception('unexpected document');
		}
		
		
	}
	
	
}

class FakeResource implements Resource {
	
	public function getOwner(){}

	public function getApplicationNames(){}
	public function getApplication($name){}
	
	public function getCollectionNames(){}
	public function getCollection($name) {
		if($name=='db.styles') {
			return new FakeCollection();			
		} else {
			throw new Exception('unexpected collection');
		}
		
	}
	
	
}


abstract class FileApplicationTest extends AbstractTest {
	
	
	public function _testGet() {
		$this->_app=new FileApplication(
			new FakeResource()
		);
		$this->_app->serve('db.styles/style.js');
		
	}
	
	
	
}

*/

?>